package com.wmh.baseservice.user.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.Version;
import com.baomidou.mybatisplus.annotation.TableId;
import java.io.Serializable;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.util.List;
import java.util.Arrays;
import java.util.ArrayList;

/**
 * @author wmh generator
 * @since 2022-09-21
 */
@ApiModel(value="UsEvaluate对象", description="用户评价表")
public class UsEvaluate implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "状态:	-1：差评	0：中评	1：好评")
    private Integer status;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "版本号")
    @Version
    private Integer version;

    private Date createTime;

    private Date updateTime;

    @ApiModelProperty(value = "用户id")
    private Long usId;

    @ApiModelProperty(value = "项目id(果蔬、产品)")
    private Long itemId;

    @ApiModelProperty(value = "1、果蔬 2、商品 3、土地 4、团购商品 5、平台商品")
    private Integer type;

    @ApiModelProperty(value = "评价内容")
    private String content;

    @ApiModelProperty(value = "评论图片、最多三张")
    private String img;

    @ApiModelProperty(value = "商家id")
    private Long merchantId;

    @ApiModelProperty(value = "订单号")
    private String orderNum;

    @ApiModelProperty(value = "评分")
    private Double rate;


    public Long getId() {
        return id;
    }

    public UsEvaluate setId(Long id) {
        this.id = id;
        return this;
    }
    public Integer getStatus() {
        return status;
    }

    public UsEvaluate setStatus(Integer status) {
        this.status = status;
        return this;
    }
    public String getRemark() {
        return remark;
    }

    public UsEvaluate setRemark(String remark) {
        this.remark = remark;
        return this;
    }
    public Integer getVersion() {
        return version;
    }

    public UsEvaluate setVersion(Integer version) {
        this.version = version;
        return this;
    }
    public Date getCreateTime() {
        return createTime;
    }

    public UsEvaluate setCreateTime(Date createTime) {
        this.createTime = createTime;
        return this;
    }
    public Date getUpdateTime() {
        return updateTime;
    }

    public UsEvaluate setUpdateTime(Date updateTime) {
        this.updateTime = updateTime;
        return this;
    }
    public Long getUsId() {
        return usId;
    }

    public UsEvaluate setUsId(Long usId) {
        this.usId = usId;
        return this;
    }
    public Long getItemId() {
        return itemId;
    }

    public UsEvaluate setItemId(Long itemId) {
        this.itemId = itemId;
        return this;
    }
    public Integer getType() {
        return type;
    }

    public UsEvaluate setType(Integer type) {
        this.type = type;
        return this;
    }
    public String getContent() {
        return content;
    }

    public UsEvaluate setContent(String content) {
        this.content = content;
        return this;
    }
    public String getImg() {
        return img;
    }

    public UsEvaluate setImg(String img) {
        this.img = img;
        return this;
    }
    public Long getMerchantId() {
        return merchantId;
    }

    public UsEvaluate setMerchantId(Long merchantId) {
        this.merchantId = merchantId;
        return this;
    }
    public String getOrderNum() {
        return orderNum;
    }

    public UsEvaluate setOrderNum(String orderNum) {
        this.orderNum = orderNum;
        return this;
    }
    public Double getRate() {
        return rate;
    }

    public UsEvaluate setRate(Double rate) {
        this.rate = rate;
        return this;
    }

    public static final String ID = "id";

    public static final String STATUS = "status";

    public static final String REMARK = "remark";

    public static final String VERSION = "version";

    public static final String CREATE_TIME = "create_time";

    public static final String UPDATE_TIME = "update_time";

    public static final String US_ID = "us_id";

    public static final String ITEM_ID = "item_id";

    public static final String TYPE = "type";

    public static final String CONTENT = "content";

    public static final String IMG = "img";

    public static final String MERCHANT_ID = "merchant_id";

    public static final String ORDER_NUM = "order_num";

    public static final String RATE = "rate";

    @Override
    public String toString() {
        return "UsEvaluate{" +
            "id=" + id +
            ", status=" + status +
            ", remark=" + remark +
            ", version=" + version +
            ", createTime=" + createTime +
            ", updateTime=" + updateTime +
            ", usId=" + usId +
            ", itemId=" + itemId +
            ", type=" + type +
            ", content=" + content +
            ", img=" + img +
            ", merchantId=" + merchantId +
            ", orderNum=" + orderNum +
            ", rate=" + rate +
        "}";
    }

    public final static String[] getFields(String ...noField){
        List<String> list = new ArrayList<>(Arrays.asList(
            UsEvaluate.ID
            ,UsEvaluate.STATUS
            ,UsEvaluate.REMARK
            ,UsEvaluate.VERSION
            ,UsEvaluate.CREATE_TIME
            ,UsEvaluate.UPDATE_TIME
            ,UsEvaluate.US_ID
            ,UsEvaluate.ITEM_ID
            ,UsEvaluate.TYPE
            ,UsEvaluate.CONTENT
            ,UsEvaluate.IMG
            ,UsEvaluate.MERCHANT_ID
            ,UsEvaluate.ORDER_NUM
            ,UsEvaluate.RATE
        ));
        list.removeAll(new ArrayList<>(Arrays.asList(noField)));
        return list.toArray(new String[0]);
    }
}